<%-- 
    Document   : delete
    Created on : Apr 6, 2011, 9:43:54 AM
    Author     : Noi Nho
--%>

<%@page import="dao.TourDAO"%>
<%@page import="dto.Tour"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
<c:if test="${param['tourID']=='' || param['tourID']==null}">
    <jsp:forward page="administrator.jsp?page=tour" />
</c:if>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Delete Tour</title>
    </head>
    <body
        <a href="administrator.jsp?page=tour">Tour Management</a>
        <br>
        <form action="AdminAction?page=tour&action=delete&tourID=${param['tourID']}" name="tourDelete" method="post">
            <%
            TourDAO tourDAO = new TourDAO();
            Tour tour = tourDAO.getTour(Integer.parseInt(request.getParameter("tourID").toString()));
                        if (tour != null) {
                            request.setAttribute("tour", tour);
%>
        Tour ID: <%out.println(tour.getTourID());%>
        <br>
        Tour Category ID: <%out.println(tour.getTourCate().getTourCateID());%>
        <br>
        Tour Name:<%out.println(tour.getName());%>
        <br>
        Price: <%out.println(tour.getPrice());%>
        <br>
        Description: <%out.println(tour.getDescription());%>
         <br>
            <input type="submit" name="submit" value="Ok">
            <input type="reset" name="reset" value="Cancel">
            <%
                        }
            %>
        </form>

    </body>
</html>
